<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%> 
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%>
<%
	if(session.getAttribute("password2")==null){
		response.sendRedirect( "login2.jsp?url=user/activation.jsp");
		return;
	}
%>
<fmt:setLocale value="${empty cookie['language'].value?'zh_CN':cookie['language'].value}"/>
	<fmt:setBundle basename="i18n.itilbase"/>
	<c:set var="lang" value="${empty cookie['language'].value?'zh_CN':cookie['language'].value}"/>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<link href="web/css/css.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="scripts/jquery/jquery-1.4.2.min.js"></script>
<script type="text/javascript" src="web/js/index.js"></script>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title><fmt:message key="i18n.userAccountJihuoTitle"/>-<fmt:message key="i18n.title"/></title>
<script>


function investmentLevel(){
	$.post('investmentLevel!findInvestmentLevelInfo.action','ilDTO.levelName=${session.registerLevel}',function(data){
		if(data!=null){
			$('#activationMoney').text(data.investmentFunds);
			if(data.investmentFunds>ac_balance){
				$('#isAllowActivation').html('<span style="color:red">Insufficient balance cannot be activated(余额不足无法激活)!</span>');
			}else{
				$('#isAllowActivation').html('<a href="javascript:accountActivate();">Activated immediately(立即激活)</a>');
			}
		}
	});
}
$(function(){
	investmentLevel();
});
</script>
</head>
<body>

<div class="zhong">
	<jsp:include page="tm-head.jsp"></jsp:include>
	<script type="text/javascript">var ac_balance='${ac.balance}';</script>
  	<div class="main">
  	<div class="right_top_img">

       <!-- affiche -->
	     	<div class="right_top_img">
	       		<div  class="notice_title"><span  style="float:left"><fmt:message key="i18n.userAccountJihuoTitle"/><a href="activation.jsp">[<fmt:message key="i18n.shuaxin"/>]</a></span></div>
		        <div style="border:dashed 1px #84888a;padding: 5px;" align="left" >
		        	<c:if test="${empty ac.status or ac.status eq 'NotActivation'}">
		        	<table width="100%">
		        		<tr>
		        			<td><fmt:message key="i18n.zhanghuBalance"/>:${ac.balance}</td>
		        		</tr>
		        		<tr>
		        			<td><fmt:message key="i18n.jihuoEdu"/>:<span id="activationMoney"></span></td>
		        		</tr>
		        		<tr>
		        			<td>
		        				<div id="isAllowActivation"></div>
		        			</td>
		        		</tr>
		        	</table>
		        	</c:if>
		        	<c:if test="${ac.status eq 'Activation'}">
		        		<span style="font-size: 16px;font-weight: 600px;color: red;"><fmt:message key="i18n.accountTwoTips"/></span>
		        	</c:if>
		        	<br>
		        	<div style="color: red;font-size: 16xp;"><b>**<fmt:message key="i18n.czlianxiSF"/><a href="companyFinancial.jsp" target="_blank" style=""><fmt:message key="i18n.companyCW"/></a>**</b></div>
				</div>
		 	</div>
	      <!-- end for affiche -->
	 </div>
    <div class="clear"></div>
  </div>
  <jsp:include page="foot.jsp"></jsp:include>
</div>
<script src="web/js/meun.js" type="text/javascript"></script>
</body>
</html>